package cn.com.surker.oa.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * OA推送消息
 * </p>
 *
 * @author admin
 * @since 2022-11-26
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class OaSendMessage implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 标识
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 业务ID
     */
    private Long bizId;

    /**
     * 业务流程类型(流程表单名称)
     */
    private String bizType;

    /**
     * 核销code
     */
    private String code;

    /**
     * 接收者ID
     */
    private Long uid;

    /**
     * 接收者账号
     */
    private String username;

    /**
     * 消息接收者
     */
    private String name;

    /**
     * 标题
     */
    private String title;

    /**
     * 副标题
     */
    private String subTitle;

    /**
     * 内容
     */
    private String content;

    /**
     * 访问URL
     */
    private String url;

    /**
     * 审批类型(0:主办,1:会签)
     */
    private Integer examineType;

    /**
     * 公司ID
     */
    private Long orgId;

    /**
     * 公司名称
     */
    private String orgName;

    /**
     * 部门ID
     */
    private Long detId;

    /**
     * 部门名称
     */
    private String detName;

    /**
     * 类型(0:审批通知，1:审核完成通知，2:驳回通知，3:处理完成通知)
     */
    private Integer type;

    /**
     * 抄送类型(0:正常发送,1：抄送总监)
     */
    private Integer ccType;

    /**
     * 是否回调(0:未回调1:已回调)
     */
    private Integer isCallback;

    /**
     * 状态(0:启用1:禁用)
     */
    private Integer status;

    /**
     * 备注
     */
    private String remark;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;

    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date updateTime;

    public OaSendMessage() {}

    public OaSendMessage(Long bizId, String bizType, String code, Long uid, String username, String name,
                         String title, String subTitle, String content, String url, Integer examineType,
                         Long orgId, String orgName, Long detId, String detName, Integer type, Integer isCallback,
                         Integer status, String remark, Date createTime, Date updateTime) {
        this.bizId = bizId;
        this.bizType = bizType;
        this.code = code;
        this.uid = uid;
        this.username = username;
        this.name = name;
        this.title = title;
        this.subTitle = subTitle;
        this.content = content;
        this.url = url;
        this.examineType = examineType;
        this.orgId = orgId;
        this.orgName = orgName;
        this.detId = detId;
        this.detName = detName;
        this.type = type;
        this.isCallback = isCallback;
        this.status = status;
        this.remark = remark;
        this.createTime = createTime;
        this.updateTime = updateTime;
    }
}
